package com.agileboot.domain.bank.query;

import cn.hutool.core.util.StrUtil;
import com.agileboot.common.core.page.AbstractPageQuery;
import com.agileboot.domain.bank.db.QuestionBank;
import com.agileboot.domain.medicine.db.Medicine;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;

/**
 * @author lx
 */
@EqualsAndHashCode(callSuper = true)
@Data
@NoArgsConstructor
public class ExamQuery extends AbstractPageQuery<QuestionBank> {
    //题库名字
    private String bankName;

    @Override
    public QueryWrapper<QuestionBank> addQueryCondition() {
        QueryWrapper<QuestionBank> queryWrapper = new QueryWrapper<QuestionBank>()
                .like(StrUtil.isNotEmpty(bankName), "bank_name", bankName)
                .eq("deleted", 0);
        return queryWrapper;
    }
}
